//
//  EJPhotoSelectDefine.h
//  EJPhotoBrowser
//
//  Created by LiuShuang on 2019/8/8.
//  Copyright © 2019 LiuShuang. All rights reserved.
//

#ifndef EJPhotoSelectDefine_h
#define EJPhotoSelectDefine_h

#import "UIView+EJFrame.h"


#ifndef weakify
    #if DEBUG
        #if __has_feature(objc_arc)
        #define weakify(object) autoreleasepool{} __weak __typeof__(object) weak##_##object = object;
        #else
        #define weakify(object) autoreleasepool{} __block __typeof__(object) block##_##object = object;
        #endif
    #else
        #if __has_feature(objc_arc)
        #define weakify(object) try{} @finally{} {} __weak __typeof__(object) weak##_##object = object;
        #else
        #define weakify(object) try{} @finally{} {} __block __typeof__(object) block##_##object = object;
        #endif
    #endif
#endif

#ifndef strongify
    #if DEBUG
        #if __has_feature(objc_arc)
        #define strongify(object) autoreleasepool{} __typeof__(object) object = weak##_##object;
        #else
        #define strongify(object) autoreleasepool{} __typeof__(object) object = block##_##object;
        #endif
    #else
        #if __has_feature(objc_arc)
        #define strongify(object) try{} @finally{} __typeof__(object) object = weak##_##object;
        #else
        #define strongify(object) try{} @finally{} __typeof__(object) object = block##_##object;
        #endif
    #endif
#endif



#ifndef kBottomSafeHeight

#import <EJTools/EJTools.h>

#define kBottomSafeHeight (CGFloat)(([UIDevice isiPhoneX] && (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone)) ? (34.0) : (0))

#endif


#define kToolsStatusHeight                [[UIApplication sharedApplication] statusBarFrame].size.height

#define kToolsNavStatusHeight             (kToolsStatusHeight + 44)


#endif /* EJPhotoSelectDefine_h */
